{% extends "RegardNewsBundle::layout.html.twig" %}

{% block title %}{{ news.title }} - Parfumerie Regard Marseille{% endblock %}

{% block content %}

<div id="NEWS_DETAILS">
          
    <div>
		<a href="{{ path('regard_news_list') }}">
			< Retour &agrave; la liste des news
		</a>
	</div>
	<br />
	
	<div id="notice">
		{% for flashMessage in app.session.flashbag.get('notice') %}
			{{ flashMessage }}
		{% endfor %}
	</div>
	
	<div class="div_news">
		<div class="div_image">
			<img src="{{ asset('img/content/'~news.image) }}" title="{{ news.title }}" alt="{{ news.title }}"/>
			{# <img src="{{ asset('img/produits/'~product.picture) }}" title="{{ product.name }}" alt="{{ product.name }}"/> #}
		</div>
		<div class="div_news_text">
			<div class="div_title">
				<span class="news_title">
					<a href="{{ path('regard_news_show', 
									{'newsId': news.id, 'newsTitle': news.title|replace({' ': "-"})}) }}"
									style="">
						{{ news.title }}
					</a>
				</span>
				<span class="news_date">
					&nbsp;(Ajout&eacute; le {{ news.date|date('d.m.Y') }})
				</span>
				<span class="news_link">
				{% if is_granted('ROLE_ADMIN') %}
					<span>
						&nbsp;<a href="{{ path('regard_news_edit', {'newsId': news.id}) }}">Modifier</a>
					</span>
					<span>
						&nbsp;&#124;&nbsp;
					</span>
					<span>
						&nbsp;<a href="{{ path('regard_news_delete', {'newsId': news.id}) }}">Supprimer</a>
					</span>
				{% endif %}
				</span>
			</div>
			<div class="div_description">
				<span>
					{{ news.content|nl2br }}
				</span>
			</div>
		</div>
	</div>
	
	<div id="div_facebook">
		<div class="fb-comments facebook-iframe" data-href="http://parfumerieregard.com" data-width="550" data-num-posts="5"></div>
	</div>
	
</div>

{% endblock %}